import { acceptHMRUpdate, defineStore } from "pinia";
import { ref } from "vue";

export const useAppStore = defineStore("app", () => {
  const secondTitle = ref<string>();
  const setSecondTitle = (title: string | undefined) => (secondTitle.value = title);

  return {
    secondTitle,
    setSecondTitle,
  };
});

if (import.meta.hot) {
  import.meta.hot.accept(acceptHMRUpdate(useAppStore, import.meta.hot));
}
